package com.frxuexi.park2303.fragment

import android.os.Bundle
import androidx.fragment.app.Fragment
import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
import com.blankj.utilcode.util.ToastUtils
import com.frxuexi.base.mvi.BaseViewFragment
import com.frxuexi.base.utils.ArouterManager
import com.frxuexi.base.utils.LiveDataBus
import com.frxuexi.park2303.R
import com.frxuexi.park2303.databinding.FragmentServiceBinding
import org.greenrobot.eventbus.EventBus
import org.greenrobot.eventbus.Subscribe
import org.greenrobot.eventbus.ThreadMode


class ServiceFragment : BaseViewFragment<FragmentServiceBinding>() {
    override fun getBind(): FragmentServiceBinding {
        return FragmentServiceBinding.inflate(layoutInflater)
    }

    override fun initView() {
        binding.servicePark.setOnClickListener {
            ArouterManager.navigation(requireContext(),"/park/ParkActivity")
        }
        binding.serviceRepair.setOnClickListener {
            ArouterManager.navigation(requireContext(),"/repair/RepairActivity")
        }
        binding.serviceVisit.setOnClickListener {
            ArouterManager.navigation(requireContext(),"/visit/VisitActivity")
        }
        binding.serviceNotice.setOnClickListener {
            ArouterManager.navigation(requireContext(),"/app/NoticeActivity")
        }

        binding.serviceNews.setOnClickListener {
            ArouterManager.navigation(requireContext(),"/app/NewsActivity")
        }

        binding.serviceSign.setOnClickListener {
            ArouterManager.navigation(requireContext(),"/sign/SignActivity")
        }



//        EventBus.getDefault().post("hello")

//        LiveDataBus.with<String>("key").postValue("myValue")


    }



}